package com.future.north.utils;

public class ServiceResult<L extends Object> {
    Integer errorCode = 0;
    Boolean success = Boolean.FALSE;
    Object body = null;
    String message = "";

    public ServiceResult() {
        this.success = Boolean.TRUE;
    }

    public ServiceResult(Integer errorCode, String message) {
        this.success = Boolean.FALSE;
        this.errorCode = errorCode;
        this.message = message;
    }

    public ServiceResult(Object body) {
        this.success = Boolean.TRUE;
        this.body = body;
    }

    public Integer getErrorCode() {
        return errorCode;
    }

    public void setErrorCode(Integer errorCode) {
        this.errorCode = errorCode;
    }

    public Boolean getSuccess() {
        return success;
    }

    public void setSuccess(Boolean success) {
        this.success = success;
    }

    public Object getBody() {
        return body;
    }

    public void setBody(Object body) {
        this.body = body;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
